<template>
  <div>
    <h3 class="dialog-plate-title"><span>当日体征检测</span></h3>
    <el-form :inline="true" :model="vitalsignsForm"  label-width="100px" class="demo-ruleForm">
      <el-form-item label="体重/kg" prop="weight"><el-input v-model="vitalsignsForm.weight" class="width220" :disabled="disabled"/></el-form-item>
      <el-form-item label="体温/℃" prop="animalHeat"><el-input v-model="vitalsignsForm.animalHeat"  class="width220" :disabled="disabled"/> </el-form-item>
      <el-form-item label="脉搏/B/M" prop="pulse"><el-input v-model="vitalsignsForm.pulse"  class="width220" :disabled="disabled"/></el-form-item>
      <el-form-item label="血压/KPa">
        <el-input  v-model="vitalsignsForm.lowBlood"  class="width110" :disabled="disabled"/>
        -
        <el-input  v-model="vitalsignsForm.highBlood"  class="width110" :disabled="disabled"/>
      </el-form-item>
      <el-form-item label="体检护士"><el-input v-model="vitalsignsForm.bodyCheckWorkerName" disabled></el-input></el-form-item>
    </el-form>
    <h3 class="dialog-plate-title"><span>历史体征</span></h3>
    <el-table ref="multipleTable" :data="tableList"  stripe border>
      <el-table-column prop="weight" label="体重/kg" sortable min-width="120"></el-table-column>
      <el-table-column prop="animalHeat" label="体温/℃" sortable min-width="120"></el-table-column>
      <el-table-column prop="pulse" label="脉搏/B/M" sortable min-width="120"></el-table-column>
      <el-table-column prop="lowBlood" label="血压/KPa" sortable min-width="120"></el-table-column>
      <el-table-column prop="bodyCheckWorkerName" label="体检护士" sortable min-width="120"></el-table-column>
      <el-table-column prop="recodeCreateTime" label="体检时间" sortable min-width="120"></el-table-column>
    </el-table> 
  </div>
</template>
<script>
import {todayVitalSigns,historyVitalSignsList} from "plugins/axios/inquiryRecord.js"
export default {
  props:{
    bodyRecodeId:{
      type:[String,Number]
    },
    providerId:{
      type:[String,Number]
    },
    disabled:{
      type: Boolean,
      default:false
     
    }
  },
  data(){
    return{
      vitalsignsForm:{},
      tableList:[]
    }
  },
  created(){},
  mounted(){
    
  },
  watch:{},
  computed:{},
  methods:{
    init(){
      this.getTodayVitalSigns();
      this.getHistoryVitalSignsList();
    },
    /**获取今日体征监测*/ 
    getTodayVitalSigns(){
      let self = this;
      todayVitalSigns(self.bodyRecodeId).then(res=>{
        self.vitalsignsForm=res.content;
      })
    },
      /**获取历史体征监测*/ 
    getHistoryVitalSignsList(){
       let self = this;
      historyVitalSignsList(self.providerId ).then(res=>{
        self.tableList=res.content;
      })
    }
  }
}
</script>
<style scoped>
</style>